// 求支撑树
void getTree(tree root,graph g){
    int visited[maxsize]={0};
    Node r;
    Node root=(Node)malloc(sizeof(struct node));
	root->data=v;
    queue<tree> q;
    q.push(root);
    while(!q.empty()){
        r=q.top();
        q.pop();
        int i=0;
        for(en p=g->vertices[i].firstArc;p!=NULL;p=p->next){
            if(!visited[p->adjvex]){
                r->child[i]=(Node)malloc(sizeof(struct node));  //将邻接顶点转换成树节点
				r->child[i]->data=p->adjvex;
				visited[p->adjvex]=1; //标记访问
				q.push(r->child[i]); //入队
				i++;
            }
        }
    }
    return root;
}